<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="base.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>
	  <c:choose>
		<c:when test="${type == 0}">创建任务</c:when>
		<c:when test="${type == 1}">提交想法</c:when>
		<c:when test="${type == 2}">报告问题</c:when>
	</c:choose>
</title>
<link href="${basePath }/styles/style.css" rel="stylesheet" type="text/css" />
<link href="${basePath }/scripts/easy_validator/css/validate.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="${basePath}/scripts/jquery.js"></script>
<script type="text/javascript" src="${basePath }/scripts/easy_validator/js/easy_validator.js"></script>
<script type="text/javascript" src="${basePath }/scripts/easy_validator/js/jquery.bgiframe.min.js"></script>
<script type="text/javascript">
	$(document).ready(function(){
		$(".btn_submit").click(function(){
			$("form:last").submit();		
		});
	});
</script>
</head>

<body>	    
	<%@ include file="header.jsp"%>
		<%@ include file="secondary-bar.jsp"%>
		<%@ include file="sidebar.jsp"%>
	<div id="right">
    <div class="column">
    	<h3 class="tabs_involved">
        <c:choose>
		<c:when test="${type == 0}"><img src="images/task.png" />创建新任务</c:when>
		<c:when test="${type == 1}"><img src="images/idea.png" />添加新想法</c:when>
		<c:when test="${type == 2}"><img src="images/bug.png" />报告新问题</c:when>
	</c:choose>
        </h3>
        <hr />
        <div class="module_content">
        	<form action="issues!add.jspx" method="post">
        	<div class="issue_items">
            	<h4 class="issue_title">标题</h4>
                <input type="text" class="input_style issues_title" name="issues.title"  tip="不能为空" reg="^.+$"  tabindex="1"/>
            </div>
            <div class="issue_items">
            	<h4 class="issue_title">内容</h4>
                <textarea name="issues.content" class="textarea_style issues_content"  tip="不能为空" reg="^.+$" tabindex="2"></textarea> 
            </div>
            <input type="hidden" name="createUserId" value="${sessionScope.currUser.id }" />
            <input type="hidden" name="pid" value="${pid }"/>
            <input type="hidden" name="issues.type" value="${type }"/>
             <div class="issue_items">
            	<h4 class="issue_title">里程碑</h4>
                <select name="milestoneId" class="select_style"  tabindex="3">
                	<c:forEach items="${milestoneList }" var="m">
                		<option value="${m.id }">${m.name }</option>
                	</c:forEach>
                </select> 
            </div>
          
            </form>   
            </div>
              <div class="actions">
                <span class="new_task">
                <a  class="btn_submit"  href="#">
                <c:choose>
		<c:when test="${type == 0}">创建任务</c:when>
		<c:when test="${type == 1}">提交想法</c:when>
		<c:when test="${type == 2}">报告问题</c:when>
	</c:choose></a>
                </span>                    
            </div> 
        </div>	
    </div>
</body>
</html>
